<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <title> - 会员管理</title>
    <meta name="keywords" content="">
    <meta name="description" content="">

    <link rel="shortcut icon" href="favicon.ico"> <link href="__CSS__/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="__CSS__/font-awesome.css?v=4.4.0" rel="stylesheet">

    <link href="__CSS__/animate.css" rel="stylesheet">
    <link href="__CSS__/style.css?v=4.1.0" rel="stylesheet">
    <style>
        .pagination{
            margin-left: 500px;
        }

    </style>
</head>

<body class="gray-bg">
    <div><h1>用户管理界面</h1></div>
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="row">
            <div class="container">
                <form action="{:url('User/index')}" class="form" method="post">
                    <div class="form-group">
                        <div class="col-sm-10 ">
                            <input type="text" class="form-control" placeholder="请输入需要查询的用户" name="username">
                        </div>
                        <button type="submit">搜索</button>
                    </div>
                </form>
            </div>
            <div class="row">

            </div>
            <div class="row">
            <form action="{:url('User/delete')}" method="post">
            <table class="table table-hover table-bordered text-center">
                   <thead >
                      <tr >
                          <th class="text-center"><span id="qx">全选</span> <span id="fx">全不选</span></th>
                          <th class="text-center">用户ID</th>
                          <th class="text-center">账户</th>
                          <th class="text-center">密码</th>
                          <th class="text-center">个人电话</th>
                          <th class="text-center">家庭电话</th>
                          <th class="text-center">头像</th>
                          <th class="text-center">邮箱地址</th>
                          <th class="text-center">qq号码</th>
                          <th class="text-center">微信账号</th>
                          <th class="text-center">账户余额</th>
                          <th class="text-center">管理操作</th>
                      </tr>
                   </thead>
                   <tbody>
                   {volist name='list' id='user'}
                      <tr>
                          <td><input type="checkbox" name="{$user.id}" value="{$user.id}"></td>
                          <td>{$user.id}</td>
                          <td>{$user.username}</td>
                          <td>{$user.password}</td>
                          <td>{$user.mobile}</td>
                          <td>{$user.home_phone}</td>
                          <td><img src="__PUBLIC__/{$user.head_img}" alt=""></td>
                          <td>{$user.email}</td>
                          <td>{$user.qq}</td>
                          <td>{$user.WeChat}</td>
                          <td>{$user.balance}</td>
                          <td><button class="btn btn-info"><a href="{:url('User/modify')}?id={$user.id}">编辑</a></button> <button class="btn btn-danger">
                          <a href="{:url('User/delete')}?id={$user.id}">删除</a></button></td>
                      </tr>
                   {/volist}
                   </tbody>
               </table>
                    <button class="btn btn-primary pull-left" type="submit" style="position: absolute; top:20px;">批量删除</button>
               </form>
            </div>
            <div class="center-block">{$page}</div>
        </div>
    </div>

    <!-- 全局js -->
    <script src="__JS__/jquery.min.js?v=2.1.4"></script>
    <script src="__JS__/bootstrap.min.js?v=3.3.6"></script>



    <!-- 自定义js -->
    <script src="__JS__/content.js?v=1.0.0"></script>



    <script>
        $(document).ready(function () {
            $('.contact-box').each(function () {
                animationHover(this, 'pulse');
            });
        });

        $("#qx").click(function() {
                $("input").each(function() {
                    $(this).attr("checked", true);
                });
        });

        $("#fx").click(function() {
                $("input").each(function() {
                    $(this).attr("checked", false);
                });
        });
    </script>
</body>

</html>
